<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class InitUpdate84 extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::table('codes', function (Blueprint $table) {
            
            $table->string('code_type', 20)->comment('兑换码类型, coupon为优惠卡券 card为道具卡  score为积分  redpack为红包 exclude_card排除卡 show_card透视卡 chip为碎片')->change();

            $table->integer('prize_total')->nullable()->comment('每份兑换物的数量');

            $table->integer('chip_id')->nullable()->index()->comment('碎片id');
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        //
    }
}
